package com.fjzn.detect.core.utils.sign;

public class RSAKeyBean {

    public static String RSA_PRI = "MIICdQIBADANBgkqhkiG9w0BAQEFAASCAl8wggJbAgEAAoGBAIwlA8P6x2SSdFLJ4BIrGDWOYl3NOPNT0wIofsR9BaoE6J8OEMFmjZtDPpQ5SLxdvMl4TV4jcvdzjaY+EXnUYRSsKDgStgrzN//BtQd5hJ9UZP0Givns+/OtX6VDAnVAPmBzOhxVe3LW6BfCiiLUBrNv3ZJnRg0wlyGOL+jNLDp7AgMBAAECgYBMisLdvRA+G8cwmFWrVqIoThXniXi7XWL34Mor4uS/EWNDy9jW6H4a+MUrC4Zwavn7R5tp+Q6HnDMXQvskgRxr7nf4BC+oWqNuce/BQLOQ9c0X2uzreDFD7Y2THvDFRQ1/je3AjBBDLt3oAiIp6ioj5kjEyGlk7/bjUIdLNs5hgQJBAN4upEewFXYNQ7qoPDzsEyZREV7nDFlYnE+DjyGqNdsLD9sMBvnbLw3KYoqD62wdi5P+TNRcLhaLjmYa/BAIAuECQQChecRXCKw//Wz83TIbu8uUhfDVMXpzF020nhLO2pliLUKF+dPGahnEN1z2YbR2zQiO+6S3VJlNbTvgleu1TkTbAkAUfYCxC9Au3vJMGI/Vnn/1nKxZcD13T/C6dIuSszvcQ5zmuqk6CbjBMNT9qUTg56ijsWQsgYPOmHg9emecouCBAkAvD2nlY6Wv0JAe8ehUpNqkIpUZzR2+xR/kb91TY+on7sDggvrxbKKtyOTS+Y66wO6pnTVYKNO0+QzmW0siv/jZAkAd0Ob/Inaz/MeDfr2jJ0NTxvg6hLjApaO/uzC+3sUn/4CGK7o6Kr4etVFIdkht3r+qBmHDG5QUTy9ahCJDubha";

    public static String RSA_PUB = "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCMJQPD+sdkknRSyeASKxg1jmJdzTjzU9MCKH7EfQWqBOifDhDBZo2bQz6UOUi8XbzJeE1eI3L3c42mPhF51GEUrCg4ErYK8zf/wbUHeYSfVGT9Bor57PvzrV+lQwJ1QD5gczocVXty1ugXwooi1Aazb92SZ0YNMJchji/ozSw6ewIDAQAB";

    public static void main(String[] args){
        String str = "dZgf4bDK8iMeGxBoAdnPvgh7elX2N7xSaGZGMWSUqd+5pHC1qSq9PzER14rlZPepareZNpkkajSYt4kPnXHIvdjLmRv2RC+FX2E777QgGQD/gTKc7QeZZAkzM1FBFkONeR37aXtJ3+OmHJ5eQGngbZna+OLiCrKY3U8Dtlv1y54=";
        System.out.println(RSAUtils.decryptPriKey(str,RSA_PRI));


        String content = "helloworld";

        String privateE = RSAUtils.encryptPriKey(content,RSA_PRI);

        System.err.println(privateE);

        String publicD = RSAUtils.decryptPubKey(privateE,RSA_PUB);

        System.err.println(publicD);

        String publicE = RSAUtils.encryptPubKey(content,RSA_PUB);

        System.err.println(publicE);


        String privateD = RSAUtils.decryptPriKey("RCScqukQEU1Uofr1Z55bPo2mGC3vaWdcZgWhfpabQ1yvTysdt7CxpPQJU9TOqzSXoEVAWHYJz/d3J27xgnKOB7wH4pf68LMDuZ09RRZbngFERf+XvTxoUmuYD8z9PX+wM7SGfTKpnMY4E7pxUXnRzp2mdts31YXTmFB2Rq0iWag=",RSA_PRI);

        System.err.println(privateD);
    }


}
